package com.int_tech.messionLog.entity;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.*;
import java.util.Date;

/**
 * Created by liubch on 2018/5/27.
 */
@Entity
@Table(name = "c_mession_log_show")
@DynamicInsert
@DynamicUpdate
@Getter
@Setter
@ToString
@Accessors(chain = true)
public class MessionLogShow {

    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    @Column(length = 8)
    private Integer id;

    //车牌号（020BZ5266）
    @Column(length = 64)
    private String carNumber;

    //rtc时间存储
    @Column(length = 64)
    private String rtcTime;

    //gps是否成功；1，成功，2失败
    @Column(length = 2)
    private int gpsIsFail;

    //gps上传时间
    @Column(length = 64)
    private String gepUploadTime;

    //坐标（40.073321)
    @Column(length = 64)
    private String lat;

    //坐标（116.593950）
    @Column(length = 64)
    private  String lng;

    //任务编号(2017010AN9630)
    @Column(length = 64)
    private  String messionNumber;

    //创建时间
    @Temporal(TemporalType.TIMESTAMP)
    @Column(updatable = false)
    private Date createTime;

    //修改时间
    @Temporal(TemporalType.TIMESTAMP)
    private Date updateTime;

    //开关门（open,close）
    @Column(length = 64)
    private String doorMessage;

    //任务编号递增码
    @Column(length = 8)
    private String messionCount;
}
